package com.todo.member.iface.backend.request;

import com.todo.common.common.entity.CurrentStaff;
import com.todo.common.utils.StringUtils;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

/**
 * @author azhebuxing
 * @date 2025/2/12 20:01
 * @description
 */
@Data
@Schema(title = "新增称号信息入参", description = "新增称号信息入参")
public class InsertMemberMedalInfoReq {

private CurrentStaff _staff;

    @Schema(title = "称号code", description = "称号code")
    private String medalCode;

    @Schema(title = "标题", description = "标题")
    private String title;

    @Schema(title = "描述", description = "描述")
    private String desc;

    @Schema(title = "称号分类", description = "称号分类")
    private Integer medalClassify;

    @Schema(title = "获取规则", description = "获取规则")
    private String rule;

    @Schema(title = "未获取展示图片", description = "未获取展示图片")
    private String unacquiredDisplayImg;

    @Schema(title = "获取展示图片", description = "获取展示图片")
    private String acquiredDisplayImg;

    @Schema(title = "佩戴展示图片", description = "佩戴展示图片")
    private String carryDisplayImg;

    @Schema(title = "排序", description = "排序")
    private Integer sort;

    public boolean baseCheck() {
        if (StringUtils.isBlank(medalCode) || StringUtils.isBlank(title) || StringUtils.isBlank(desc)
                || medalClassify == null || StringUtils.isBlank(rule) || StringUtils.isBlank(unacquiredDisplayImg)
                || StringUtils.isBlank(acquiredDisplayImg) || StringUtils.isBlank(carryDisplayImg) || sort == null){
            return false;
        }
        return true;
    }
}
